import { createApp } from 'vue'

import App from './App.vue'
import {createPinia} from "pinia";
import piniaPluginPersistedstate from 'pinia-plugin-persistedstate'
import router from './router'
import * as ElementPlusIconsVue from '@element-plus/icons-vue'
import "./tailwind.css"
import "@icon-park/vue-next/styles/index.css";
import Particles from '@tsparticles/vue3'
import { loadFull } from 'tsparticles'





const store = createPinia()
store.use(piniaPluginPersistedstate)
const app = createApp(App)
for (const [key, component] of Object.entries(ElementPlusIconsVue)) {
    // @ts-ignore
    app.component(key, component)
}
app.use(router)
app.use(store)
app.use(Particles, {
    init: async (engine) => {
        await loadFull(engine) // you can load the full tsParticles library from "tsparticles" if you need it
        // loadSlim 轻量级的
        // await loadSlim(engine) // or you can load the slim version from "tsparticles-slim" if don't need Shapes or Animations
    }
})

app.mount('#app')

